Method and apparatus for improved performance in encoder systems

ABSTRACT

An encoder system includes a configurable detector array, wherein the configurable detector array includes a plurality of detectors. The encoder system may also include a memory operable to store a partition map that defines a state for each of the plurality of detectors. The encoder system may also include an emitter operable to generate a flux modulated by a motion object, wherein the configurable detector array is operable to receive the flux and generate respective current outputs for each of the detectors in response to the flux. In an embodiment, the current outputs from detectors having a same state are grouped together. The encoder system may also include one or more current duplicators to duplicate the current outputs from detectors having one state to group with the current outputs from detectors having a different state. The encoder system may also adjust weights of the current outputs.

CROSS REFERENCE TO RELATED APPLICATIONS

The present application is a division of U.S. patent application Ser.No. 16/660,987, filed Oct. 23, 2019, which claims the benefit of U.S.Provisional Patent Application No. 62/755,658, filed Nov. 5, 2018, thedisclosures of which are incorporated by reference herein in theirentireties.

BACKGROUND

An encoder system, such as an optical encoder, may include anelectro-mechanical device that detects and converts positions (e.g.,linear and/or angular positions) of an object to analog or digitaloutput signals by using one or more photodetectors. There are differenttypes of encoders, such as rotary encoders and linear encoders. Anexemplary encoder system usually uses a light source, a light modulatorlocated in the source light pathway, and an encoder chip (e.g., anoptical sensor integrated circuit) including one or more photodetectorsthat receive the modulated light and generate electrical signals inresponse thereto. In some embodiments, the encoder chip includes aconfigurable photodetector array, which provides convenience andflexibility to match one encoder chip to multiple encoder modulesregardless of type and specific mechanical construction, such as codewheel or code strip configurations. In the configurable photodetectorarray, each photodetector (termed “pixel”) is assigned a state, such asone of the quadrature states corresponding to a respective quadraturetrack. However, some pixels may have contributions in more than onequadrature track but are forced to be assigned to a single quadraturestate, which causes inaccuracy in the encoder system. Furthermore,treating current outputs from a pixel in response to an incident lightwith same weight may also cause inaccuracy when the light sourcegenerates a non-uniform light intensity profile. For a high-resolutionencoder system, there is a need to find ways to better assign states andweights to the pixels.

Accordingly, to improve accuracy of an encoder system, improvements inthe encoder chip are desired.

BRIEF DESCRIPTION OF THE DRAWINGS

Aspects of the present disclosure are best understood from the followingdetailed description when read with the accompanying figures. It isemphasized that, in accordance with the standard practice in theindustry, various features are not drawn to scale. In fact, thedimensions of the various features may be arbitrarily increased orreduced for clarity of discussion.

FIG. 1 is an illustration of an exemplary transmissive optical encoder,in accordance with some embodiments.

FIG. 2 is an illustration of an exemplary pattern of quadrature-trackcode wheel slits in a transmissive optical encoder system, in accordancewith some embodiments.

FIG. 3 shows an exemplary embodiment of quadrature assignments (A+, A−,B+, B−) to a photoactive region on an optical sensor IC, superimposedupon a code wheel's quadrature track shown in FIG. 2 , in accordancewith some embodiments.

FIG. 4 shows aggregated illuminated areas of A+, A−, B+, B− regions inFIG. 3 when a code wheel is rotated clockwise at a constant rate, inaccordance with some embodiments.

FIG. 5 illustrates an exemplary configurable photodetector array andconfigured quadrature assignments to pixels in the array, superimposedupon a code wheel's quadrature track, in accordance with someembodiments.

FIG. 6 shows an exemplary schematic of quadrature assignment mechanismto a pixel in a configurable photodetector array, in accordance withsome embodiments.

FIG. 7 shows an exemplary circuit diagram of a configurablephotodetector array according to the schematic illustrated in FIG. 6 ,in accordance with some embodiments.

FIG. 8 shows an exemplary circuit diagram of an example interpolatorresistor ladder architecture that converts configurable photodetectorarray's readings into analog output with transimpedance amplifiers(TIAs), in accordance with an embodiment.

FIG. 9 illustrates another exemplary configurable photodetector arrayand configured quadrature assignments to columns in the array,superimposed upon a code wheel's quadrature track, in accordance withsome embodiments.

FIG. 10 shows another exemplary schematic of quadrature assignmentmechanism to a column in a configurable photodetector array, inaccordance with some embodiments.

FIG. 11 shows another exemplary circuit diagram of a configurablephotodetector array according to the schematic illustrated in FIG. 9 ,in accordance with some embodiments.

FIG. 12 shows an exemplary schematic of a current duplicating mechanismto assign one or a set of pixels in a configurable photodetector arrayto more than a single state, in accordance with some embodiments.

FIG. 13 shows an exemplary schematic of a current duplicating mechanismand a current weight adjusting mechanism to assign one or a set ofpixels in a configurable photodetector array to more than a single statewith adjusted weights, in accordance with some embodiments.

FIG. 14 shows an exemplary circuit diagram of a current weight adjustor,in accordance with an embodiment.

FIG. 15 shows an exemplary circuit diagram of a current duplicator witha current weight adjusting function, in accordance with an embodiment.

FIG. 16 shows an exemplary schematic of a current weight adjustingmechanism to adjusted weights of a single or a set of pixels in aconfigurable photodetector array, in accordance with some embodiments.

FIG. 17 shows a flowchart of an exemplary method of assigning currentduplication and current weight adjustment to a configurablephotodetector array, in accordance with some embodiments.

FIG. 18 shows a flowchart of an exemplary method of adjusting currentweights of a configurable photodetector array to mitigate lightintensity non-uniformity in an encoder system, in accordance with someembodiments.

DETAILED DESCRIPTION

The following disclosure provides many different embodiments, orexamples, for implementing different features of the provided subjectmatter. Specific examples of components and arrangements are describedbelow to simplify the present disclosure. These are, of course, merelyexamples and are not intended to be limiting. Any alterations andfurther modifications to the described devices, systems, methods, andany further application of the principles of the present disclosure arefully contemplated as would normally occur to one having ordinary skillin the art to which the disclosure relates. For example, the features,components, and/or steps described with respect to one embodiment may becombined with the features, components, and/or steps described withrespect to other embodiments of the present disclosure to form yetanother embodiment of a device, system, or method according to thepresent disclosure even though such a combination is not explicitlyshown. Further, for the sake of simplicity, in some instances the samereference numerals are used throughout the drawings to refer to the sameor like parts.

The present disclosure is generally related to encoder systems andmethods thereof, more particularly to an optical encoder with aconfigurable photodetector array and methods for detecting andconverting position information of a target object to analog or digitaloutput signals. For the purposes of simplicity, the embodimentsdescribed herein will use a code wheel (for rotary encoders) as anexample of the target object, although the scope of embodiments mayinclude any suitable optical detection of moving objects. For example,the principles in the present disclosure can also be used for alignmentadjustment for encoders targeted in detecting linear movements (e.g., acode strip for linear encoders). Various embodiments of the presentdisclosure enable the use of a configurable photodetector array, whichallows a single integrated circuit (IC) design for encoder modules ofvarying configurations without degradation of output signal quality,thus enabling the lower cost arising from higher volume and a simplersupply chain resulting from managing fewer IC part numbers. Further,various embodiments of the present disclosure enable a technique to moreaccurately map outputs (i.e., currents or voltages) from a configurablephotodetector array to different regions and to weight the opticalenergy contribution, which refines a mapping from the configurablephotodetector array to a code wheel or a code strip and increasesaccuracy of an overall encoder system.

A non-uniform light intensity profile of a light source may also becompensated by the illustrated technique. For the purposes ofsimplicity, the embodiments described herein will focus on currentdomain, such as current duplicators and current weight adjustors thatwill be discussed in further details below. However, the same principlecan also be applied to voltage domain, such as converting a current to avoltage by a transimpedance amplifier (TIA) then duplicating oradjusting the voltage.

Additionally, other embodiments, for example, a magnetic encoder systemmay have a configurable magnetic-field detector array to detect magneticflux changes due to modulation from a moving object, such as a codewheel or a code stripe. However, for ease of illustration, theembodiments described herein focus on optical detection, and it isunderstood that such principles may be applied to magnetic detectionsystems.

Optical encoders may include incremental and absolute encoders that areused to track motion and can be used to determine position and velocity.This can be either linear or rotary motion. Because the direction can bedetermined, very accurate measurements can be made. Regardless of typeand specific mechanical construction, optical encoders generally use thesame optical detection mechanism and components: a light source, a lightmodulator located in the source light pathway, and light detectors thatreceive the modulated light and generate electrical signals in responsethereto. The light source may include, for example, a light-emittingdiode (LED), and may emit electromagnetic radiation within the infraredto ultraviolet spectral region. In some embodiments, the light sourcemay include a laser emitter.

The light modulator is commonly in the form of a thin disk, such as acode wheel, concentric with the rotating shaft and having its facesperpendicular to the source light pathway. The code wheel may have apattern of transparent and opaque areas formed on the faces so that asthe shaft rotates, the source light passing through the wheel faces isinterrupted in accordance with the pattern. The unique light patternilluminated by the wheel is sensed by the light detectors. In response,the light detectors generate electrical signals that interchange betweena high current level (or a high voltage level) and a low current level(or a low voltage level) and that can be graphically represented ascontinuous time-varying waves. FIG. 1 depicts an embodiment of atransmissive rotary optical encoder. Within FIG. 1 , the region of acode wheel labeled “alternating opaque and transparent regions” consistsof one or more tracks. In this example, a track is the set of points onthe code wheel whose distance from the center of the shaft is between aninner radius R1 and an outer radius R2, and the opaque (e.g., bars) andtransparent (e.g., slits) regions of the track are arranged such thatthe track has discrete rotational symmetry of order N about the shaftcenter, where N≥1. One such track on an incremental encoder is known asthe quadrature track, whose order of rotational symmetry is termed thepulses per revolution (PPR) of the encoder system. The transmissiveoptical encoder in the illustrated embodiment is merely an example, andis not intended to limit the present disclosure beyond what isexplicitly recited in the claims. The principle of the presentdisclosure may also be applicable to a reflective optical encoder.

FIG. 2 depicts an example embodiment of a quadrature track. The opticalsensor integrated circuit (IC) in FIG. 1 contains a plurality ofphotoactive areas, grouped into regions, such as A+, A−, B+, and B−regions, and aligned to the quadrature track of the code wheel (i.e. ata distance from the axis of code wheel rotation between R1 and R2 of thequadrature track). Each of the A+, A−, B+, and B− regions is composed ofone or more discrete photoactive areas connected in parallel (so thatthe photocurrents of the parallel discrete photoactive areas areadditive), as described in more detail below. A light emitter (e.g., anLED) illuminates lights towards the photoactive areas. The light wouldbe blocked by the opaque regions of the track or pass through thetransparent regions and arrive at the photoactive areas.

FIG. 3 depicts an exemplary embodiment of the A+, A−, B+, and B− regionsof the optical sensor IC in an encoder system with part of the codewheel quadrature track superimposed. FIG. 4 depicts the aggregatephotocurrents of the A+, A−, B+, and B− regions as depicted in FIG. 3over a span of time assuming a constant code wheel rotation rate (hereinaggregate photocurrent is assumed to be directly proportional toaggregate illuminated area). As can be seen in FIG. 4 , the photocurrentwaveforms are periodic with period 1/(f_(CW)*PPR), where f_(CW) is therotational frequency of the code wheel and PPR is the order ofrotational symmetry of the quadrature track of the code wheel. Moreover,the photocurrent waveforms are approximately sinusoidal and are inquadrature (i.e. equal in magnitude and separated in phase by 90°). Thescheme depicted in FIG. 3 , where the photoactive areas on the sensor ICalternate spatially between the A+, B+, A−, and B− regions and areclosely matched in size and position to the geometries of the slits andbars in the quadrature track of the code wheel, is known as aphased-array design. Because the geometry of the code wheelquadrature-track slits and bars changes if the code wheel configuration(radius and PPR) changes, a phased-array design intended for use with aparticular code wheel configuration may not operate properly when usedwith a different code wheel configuration. Furthermore, different codewheels may have different slit shapes. In the illustrated embodiment,the slit shape is regular, such as a pie-shaped with a radius at eachend, and different slits may have an identical slit shape. In variousother embodiments, a slit shape may be irregular, while different slitson a same code wheel may further have different shapes. Therefore,manufacturers of incremental encoders traditionally require a differentIC design for each different code wheel configuration they deploy. Formanufacturers that make many different encoder modules inlow-to-moderate volume with configurations, this necessitates thepurchase of many different ICs in low-to-moderate volume. This resultsin a higher cost and more complex supply chain than would be needed ifthe same IC may be used for multiple encoder modules regardless ofconfiguration.

For example, if a customer normally supports 3 code wheel radii and 4different PPR per radii, then the customer would have to maintain aninventory of 12 different ASICs (at least in theory). It is thereforedesired to enable the use of a single IC design for encoder modules ofvarying configurations without significant degradation of output signalquality, thus allowing the lower cost arising from higher volume and asimpler supply chain resulting from managing fewer IC part numbers.Using a configurable photodetector array would allow the customer toinventory a single IC for a multitude of code wheel radii and PPR,generally allowing a lower cost position for the customer due to highervolumes and reduced material handling.

FIG. 5 illustrates a configurable photodetector array in an opticalsensor IC and an example of configured quadrature assignments to eachphotodetector in the array, superimposed upon a code wheel's quadraturetrack. The configurable photodetector array forms a photoactive area ofthe optical sensor IC. Each photodetector may include either aphotodiode or a phototransistor. For simplicity, a photodetector in thearray is also referred to as a pixel, and the configurable photodetectorarray is also referred to as a pixel array. In the illustrated example,the pixel array contains 5 rows by 7 columns of pixels, a total of 35pixels. In the illustrated example, a row is defined as extending alonga direction parallel to a polar axis of a code wheel, and a column isdefined as extending along a direction perpendicular to a polar axis ofa code wheel. The pixels and the pixel array in the illustratedembodiment are merely an example and is not intended to limit thepresent disclosure beyond what is explicitly recited in the claims. Theprinciple of the present disclosure may also be applicable to a pixelarray containing any number of rows and any number of columns. Further,the illustrated pixel array in FIG. 5 may represent a region of a largerarray, such as a small portion in a larger pixel array containing 64rows by 32 columns of pixels (a total of 2048 pixels). Also, a pixelarray may have a shape other than a rectangular shape, such as a squareshape, or other suitable shapes.

FIG. 5 shows an illustration of how track slits can overlap with pixels.Pixels are programmatically selected to route their currents to aparticular region (i.e., A+, A−, B+, B− regions for a quadrature trackor Y, U, V, Z, ABS regions for various other tracks such as acommutation track, index track, or an absolute track). This particularregion is also termed an assignment or a state of the pixel. Assigningstates can be performed when the optical sensor IC is powered up byreading from a pixel partition map stored in a memory module, such as anon-volatile memory. The configuration may also be updated on-the-fly.The pixel partition map stores states to each pixel in the pixel array.In the illustrated example in FIG. 5 , the pixels on rows 1-2 of column2 are set to B+ and the pixels on rows 3-5 of column 2 are set to A−,while pixels of column 1 are all set to OFF.

The pixel partition map tries to fit the states to a particular trackconfiguration. Generally, pixels configured with the same quadratureassignments form photoactive regions in proximity to a shape of theslit. In the illustrated example in FIG. 5 , the pixels with A−assignments form a photoactive region matched to the respective slit. Insome embodiments, pixels configured with the same quadrature assignmentsform photoactive regions in strip shapes. In some other embodiments, thepixels configured with the same quadrature assignments form photoactiveregions in mosaic shapes. The assignment of the pixels is typically afunction of the code wheel's radius and PPR, and a pixel array's shape,pixel numbers, and spacing. In some embodiments, the consideration ofpixel assignment also includes installation misalignments between theoptical sensor IC and the code wheel. In furtherance of someembodiments, the consideration of pixel assignments includes correctingunbalanced currents or gains and phase errors such as due toinstallation misalignments.

When the optical sensor IC is installed with a different track,individual ones of these pixels may change states to form a new pixelpattern that fits the new code wheel. Or, during an optical encoderoperation, the system may determine to incrementally change the pixelpartition map on-the-fly, and these particular pixels may be changed,such as from A− to A+, B+, or B−, together with some other pixels in thepixel array. Therefore, a pixel array provides an advantage to enablethe use of a single IC design for various code wheels. As a comparison,most existing optical encoder designs use a fixed pattern phased arrayfor detectors, such pattern exactly matches a particular code wheel,thus limiting the array to a code wheel of specific size and PPR (pulseper revolution). This is because the geometry of the code wheelquadrature-track slits and bars changes if the code wheel configuration(radius and PPR) changes, and consequently a phased-array designintended for use with a particular code wheel configuration may notoperate properly when used with a different code wheel configuration.For manufacturers that make many different encoder modules inlow-to-moderate volume with configurations, this may necessitate thepurchase of many different ICs in low-to-moderate volume. This resultsin a higher cost and more complex supply chain than would be needed ifthe same IC may be used for multiple encoder modules regardless ofconfiguration. Using optical sensor IC with a pixel array allows theuser to inventory a single IC for a multitude of code wheel radii andPPR, generally allowing a lower cost position for the user due to highervolumes and reduced material handling.

The shape of pixels may be made non-homogeneous within the pixel array.Having different size/shape pixels may reduce total system noise. Therectangular, grid-based pixels may produce a small amount of noisecompared with an ideally shaped detector that better matches the slit.Adjusting the shape to round, elliptical, or rounded corners may reduceoverall noise. Further, changing the size of individual or groups ofpixels may also improve system noise at the expected cost of increasedlayout complexity and increased modeling requirements to determine pixelmapping.

Pixels with the same assigned state are selected to route their currentstogether. A pixel array may include a plurality of pixels and aplurality of lumped current-mode outputs. Referring to FIG. 6 , acurrent output 604 from a single pixel 602 is coupled to a switch 606,such as a channel select multiplexer (MUX). The MUX 606 routes thecurrent output to one of the lumped current-mode outputs 608 (e.g.,collected by a channel summing amplifier 610). The summed currents arefurther routed to transimpedance amplifiers (TIAs) and other processingcircuitry 612. FIG. 7 illustrates an exemplary circuit diagram of thepixel array in FIG. 5 , in accordance with the schematic in FIG. 6 . Forsimplicity, only pixels at rows 1, 2 and 5 of columns 2 and 3 are shown.

Referring to FIG. 7 , each pixel includes a photoactive area with atleast two electrical terminals, in which current flows between the firstterminal (connected to all pixels in the array, also as common or groundterminal) and the second terminal (unique to each pixel, also asindividual terminal) in proportion to the optical power incident to thephotoactive area. Each pixel may have its own MUX. The second terminalis coupled to this MUX. The MUX receives configuration bits from controllines (e.g., a bus line, or an SRAM word line) and routes the individualterminal of the photoactive area to one of the lumped current-modeoutputs, no more than one of which is routed to the individual terminalat any given time. In this way, each lumped current-mode output carriescurrent equal to the sum of the photocurrents in the photoactive areasof those pixels whose switches to that output are closed. Each one ofthe lumped current-mode outputs corresponds to a respective quadraturetrack assignment (e.g., A+, A−, B+, B−). The control line may use 2 bitsto select one of the four lump quadrature track assignments of a MUX.The currents with the same quadrature track assignment are furthergrouped by a channel summing amplifier.

The pixels in a pixel array may be partitioned among the various lumpedcurrent-mode outputs based upon the configuration of the code wheel.Partitioning may be performed by writing to the memory bits to controlthe MUX. The pattern for the pixels is based on the design of the codewheel in the system. In an exemplary embodiment, a process of simulationor experimentation is used to determine the mapping for the pixels basedon the code wheel radii and the slit pattern. The result is an initialpartition map written into the memory of an ASIC to set each pixel tothe correct region. In some embodiments, the initial partition map isstill subject to a partition map adjustment during a currentdistribution and weight adjustment process before the encoder system isready for regular operations.

In some embodiments, pixels can be set to an OFF state. An examplesolution sets each pixel to one of the 4 primary regions: A+, B+, A−,B−. It may be advantageous in some cases to turn individual pixels off.For example, the control line may further use a control bit to controlturning ON or OFF of a pixel. This may be performed pixel-by-pixel orbased on entire rows or columns. Another implementation to shut a pixeloff is to add one more control bit to the MUX to select a status thatnone of the four lump current mode outputs are coupled to the individualterminal. By allowing a pixel to be turned OFF, this may allow thepixels to potentially more closely match the code wheel pattern.Further, this capability may allow better current balancing across the 4main regions, simplifying the design of the downstream blocks in theASIC like the transimpedance amplifiers (TIAs), filters, andcomparators.

The lumped current outputs in this example are routed to transimpedanceamplifiers (TIAs), such as four single ended TIAs or two differentialTIAs. This is shown in more detail with respect to FIG. 8 . Theseamplifiers convert the current output from the pixel array into voltagesignals that can be used for downstream processing. These TIAs are sizedappropriately for the current outputs from the 4 blocks. In anembodiment, The TIAs may be highly linear in order to producehigh-quality analog outputs for the quadrature tracks. In anotherembodiment, the TIAs are logarithmic, in order to accommodate a widedynamic range of input (e.g., when analog quadrature-track outputsaren't needed). The transimpedance should be large enough to keep theangular position error introduced by the amplifier's own internal noiseand offset of downstream comparators small, yet small enough to preservegood linearity at full-scale input current. Each TIAs' instance may havean adjustable current sink additive to its input, for offsetcompensation. The current sink value for a particular instance may becontrolled by a control byte corresponding to that instance. Theadjustable current sink may include latches in which to store thecontrol bit(s) (e.g., a byte).

FIG. 8 shows a circuit diagram of an exemplary interpolator resistorladder architecture that converts photodetector array readings intoanalog output with transimpedance amplifiers (TIAs). This is merely anexample. Other suitable implementations, such as other suitable numberof interpolator resistors (>2) and/or other suitable circuit topology,may also be used. In the illustrated embodiment, this block generatesanalog waveforms that are phase-shifted from the filtered A+/A−/B+/B−TIA output waveforms by between 0° and 90° in equal steps of 5.625°(=90°/16). By digitally comparing appropriate interpolated waveforms,square waves of up to 16× the frequency of the TIA outputs can begenerated in this example. The block consists of four identical resistorladders, each between the filtered outputs of two of the fourquadrature-track TIAs (A+, A−, B+, B−): one between the B+ and A−filtered TIA outputs, one between the A− and B− filtered TIA outputs,one between the B− and A+ filtered TIA outputs, and the fourth betweenthe A+ and B+ filtered TIA outputs. Various other embodiments may bescaled as appropriate to provide any number of steps.

FIG. 9 illustrates a pixel array which is similar to what has beendiscussed above with reference to the pixel array in FIG. 5 . Forexample, the pixel array in FIG. 9 also has 5 rows by 7 columns ofpixels. Different from the one in FIG. 5 , the pixel array in FIG. 9receives different pixel assignments. Specifically, in FIG. 5 pixels inthe same column may be assigned to more than one quadrature states, suchas B+ and A− quadrature states for pixels in column 2. In FIG. 9 pixelsin the same column are assigned a single quadrature state and anoptional OFF state, such as A− quadrature state and OFF state for pixelsin column 2. By assigning each column with a single quadrature state,current outputs from pixels in the same column may be summed togetherand contribute to the same state. Consequently, only one MUX is used forone column of the pixel array in such an embodiment, which greatlysimplifies circuit complexity relative to other embodiments using moreMUXs.

Referring to FIG. 10 , current outputs 1004 from a column of pixels 1002are grouped together and received by one MUX 1006. The MUX 1006 routesthe current output to one of the lumped current-mode outputs 1008 (e.g.,collected by a channel summing amplifier 1010). The lumped currentoutputs are further routed to transimpedance amplifiers (TIAs) and otherprocessing circuitry 1012.

FIG. 11 illustrates an exemplary circuit diagram of the pixel array inFIG. 9 , in accordance with the schematic in FIG. 10 . For simplicity,only pixels at rows 1, 2 and 5 of columns 2 and 3 are shown. In FIG. 11, each pixel includes a photoactive area with at least two electricalterminals, in which current flows between the first terminal (connectedto all pixels in the array, also as common or ground terminal) and thesecond terminal (unique to each pixel, also as individual terminal) inproportion to the optical power incident to the photoactive area.Instead of one MUX for each respective pixel (e.g., in FIG. 7 ), thereis one MUX for a respective column of pixels. This is because the pixelsin the same column all have the same quadrature state and the respectivecurrent outputs can be summed together and collectively feed to one MUX.In the illustrated example, summing current outputs can be achieved byphysically shorting the second terminals of the pixels in the samecolumn (as shown in FIG. 11 ) or by using a current summing amplifier(not shown) before the MUX to collect the current outputs. The MUXreceives configuration bits from control lines (e.g., a bus line, or anSRAM word line) and routes the summed current outputs from one column toone of the lumped current-mode outputs. Each one of the lumpedcurrent-mode outputs corresponds to a respective quadrature trackassignment (e.g., A+, A−, B+, B−). The control line may use 2 bits toselect one of the four lump quadrature track assignments of a MUX. Thecurrents from other columns with the same quadrature track assignmentare further grouped by a channel summing amplifier.

Individual pixels in the same column can be set to an OFF state torepresent the optimal mapping. For example, as shown in FIG. 9 , pixelsin rows 1 and 2 of column 2 are set to an OFF state to form photoactiveregions to approximate a shape of the slit. Setting the OFF state may beperformed pixel-by-pixel or based on entire rows or columns. Forexample, the control line may further use a control bit to controlturning on or off of a pixel. Another implementation to shut a pixel offis to add one more control bit to the MUX to select a status that noneof the four lump current-mode outputs are coupled to the individualterminal.

In an example practical system, pixel pattern mapping is not perfect andsome pixels have contributions in more than one quadrature track but areforced to be assigned to a single track. Referring back to FIG. 5 , thesketch shows a static orientation. In a real system, the code disk wouldrotate one slot position for a full cycle. As can be observed from theoverlapping sketch, not all pixels will map perfectly into only oneregion. Pixels at an edge of the slit may have contributions to morethan one state. For example, the pixel at row 3 of column 2 is assignedwith A−. However, more than half of the photoactive area of this pixelis not covered by the slit. Since a neighboring pixel at row 2 of column2 is assigned with B+, it is possible the pixel at row 3 of column 2contributes to both A− and B+. But the current output from this pixel isfully grouped into state A−. Another example is the pixel at row 4 ofcolumn 6 assigned with B−. However, the upper left corner of thephotoactive area of this pixel is covered by the slit, so that theportion of the current output with respect to this corner could bethought of as contributing to state A−. Similarly, besides individualpixels, a column of the pixel array may have contributions to more thanone state. Referring back to FIG. 9 , pixels in column 1 are assignedwith A+(together with OFF) and pixels in neighboring column 2 areassigned with A− (together with OFF). It is possible the pixels incolumn 2 also have contribution to state A+. However, assigning thewhole column 2 to state A− introduces mapping defects to the system.

FIG. 12 shows an illustration of how the current 1204 from one pixel ora set of pixels 1202 (e.g., a column or part of a column) could berouted to one or more states. This method enables pixels to contributeto different effective shapes thus potentially providing a better matchto the code disk slits. A current duplicator 1206 is inserted betweenthe MUXs 1208 and the pixels 1202. In an embodiment, the currentduplicator 1206 includes a current mirror to create a copy of thecurrent outputs received, and feeds the copied current outputs to morethan one MUX (e.g., two MUXs). The MUXs 1208 are set to route thereceived current output to different states, such as one for A+ andanother for A−, which are collected by respective channel summingamplifiers 1210. Thus, one pixel or a set of pixels can contribute tomore than one state. In an alternative embodiment, the two MUXs 1208 inFIG. 12 are set to route the received current outputs to the same state.For example, both MUXs 1208 are set to route the received currentoutputs to the lumped current-mode outputs A− and collected by the samechannel summing amplifier corresponding to A− assignment. This isconsidered to have doubled the original current outputs from theindividual pixel or a set of pixels, equivalently a current weightingfunction of a weighting factor of 2. The remaining functions for TIAsand processing circuitry 1212 remain the same and are omitted hereby forsimplicity.

For a pixel array similar to the one in FIG. 5 , in which each pixel maybe individually assigned one of the quadrature states, each pixel mayhave a respective current duplicator. In other words, the number of thecurrent duplicator may be equal to the total pixels in the pixel array.Alternatively, for the sake of simplifying circuits, in some embodimentsonly pixels at an edge of a slit may have a respective currentduplicator. In other words, the number of the current duplicators ismuch less than the total pixels in the pixel array. For a pixel arraysimilar to the one in FIG. 9 , in which pixels in the same column isassigned the same one of the quadrature states, each column may have arespective current duplicator. In other words, the number of the currentduplicators may be equal to the number of columns in the pixel array.Alternatively, for the sake of simplifying circuits, perhaps onlycolumns at an edge of a slit have a respective current duplicator insome embodiments. In other words, the number of the current duplicatormay be less than the number of columns in the pixel array in someexamples.

FIG. 13 shows a further improvement to the current duplicating mechanismillustrated in FIG. 12 . Particularly, a current weight adjustor 1218 isadded to each output port of the current duplicator 1206, adjustingweights of the copied current outputs before feeding to the MUXs 1208.Similar to the function of a current duplicator, the weighting functionallows a similar benefit of providing a more optimal shape to aproximity of the slit. In both cases, there are benefits beyond puregeometric mapping of pixels. It is generally preferred that the outputfrom the quadrature tracks would produce sinusoidal signals, as close aspossible to 90 degrees phase-shifted from each other. Depending on thegeometry of the code disk slit and the matching pixel assignments,distortion from an ideal sine wave could occur. In a more extreme casewhere the slits are quite wide, the pattern produced from transposingthe code disk over a set of pixels may produce a trapezoid with relativesharp edges at the transition points. This is generally not desirablefor the downstream signal processing like interpolators. Being able toweight pixels differently through these techniques enables pixels to besummed in patterns that can produce a more optimal sine wave.

FIG. 14 shows an exemplary circuit diagram of a current weight adjuster.Transistors Q0, Q1, Q2, and Q3 form a current mirror with three outputbranches, in which current outputs of Q1-Q3 (i.e., I1-I3) track thecurrent input of Q0 (i.e., I0). Since voltages across gate and source ofthese four transistors are the same, a current flowing through eachtransistor is approximately proportional to a junction size of therespective transistor. In one embodiment, ratio of the junction sizes ofQ0:Q1:Q2:Q3 is about 1:0.6:0.4:0.2. Thus, ratio of the currents ofJ0:I1:I2:I3 is also approximately 1:0.6:0.4:0.2. The output of thecurrent weight adjuster Isum is operable to take individual or a sum ofthe mirrored currents I1, I2, and I3, for example, configured bycontrolling bits from the control line. Therefore, if the weight of I0is consider as 1, the weight of the output of the current weightadjuster can be selected from a set of {0.2, 0.4, 0.6, 0.8, 1, 1.2}. Acurrent mirror with more output branches (e.g., by adding moretransistors mirrored to Q0) may achieve a finer weight adjustingresolution and/or a larger weight adjusting range.

Referring back to FIG. 13 , the current weight adjustors coupled to thesame current duplicator may have the same or different weight settings.For example, for a column that contributes 40% to state A+ and 60% tostate A−, the current duplicator copies the summed current outputs fromthe column equally, while one current weight adjustor is set to a weightof 0.4 and routes one copied current output through a MUX to group intostate A+ and another current weight adjustor is set to a weight of 0.6and routes another copied current output through another MUX to groupinto state A−.

The current duplicator and the current weight adjustors may belong toseparate circuit blocks. Alternatively, the current duplicator mayinclude a current weight adjusting function in its circuitry. FIG. 15shows an exemplary circuit diagram of a current duplicator with acurrent weight adjusting function. The circuit receives one currentinput I0 and duplicates two weighted current outputs Isum and I′sum.Similar to the current mirror in FIG. 14 , the circuit illustrated inFIG. 15 is regarded of having two sets of current mirrors. The firstcurrent mirror includes transistors Q0, Q1, Q2, and Q3. The secondcurrent mirror includes transistors Q0, Q′1, Q′2, and Q′3. Each of thecurrent outputs Isum and I′sum may be individually set to one or a sumof respective mirrored current branches. In one embodiment, ratios ofthe junction sizes of Q0:Q1:Q2:Q3 and Q0:Q′1:Q′2:Q′3 are both about1:0.6:0.4:0.2. Thus, ratios of the currents of I0:I1:I2:I3 andI0:I′1:I′2:1′3 are also approximately 1:0.6:0.4:0.2. Accordingly, eachof the current outputs Isum and I′sum has a weight adjusting range in aset of {0.2, 0.4, 0.6, 0.8, 1, 1.2}. For example, by setting Isum=+I2and I′sum=I′1+I′2, the circuit functions as a current duplicator withoutweight adjusting (or weight=1). Or, by setting Isum=I2 and I′sum=I′1,the circuit functions a current duplicator with a weight setting of 0.4for one output and a weight setting of 0.6 for another output.

Either current duplicator or current weight adjustor is optional for thepixel array. In some embodiments, the pixel array may have currentweight adjustors 1218 but no current duplicator, such as the oneillustrated in FIG. 16 . FIG. 16 shows an illustration of applying aweighting function to one pixel, or a set of pixels 1202 (e.g., a columnor part of a column), allowing a similar benefit as discussed above forproviding a more optimal shape to the proximity of the slit. In oneembodiment, weights for each pixel in the pixel array can be adjusted.In yet another embodiment, weights for each column in the pixel arraycan be adjusted. The remaining functions for MUX 1208, channel summingamplifiers 1210, TIAs and processing circuitry 1212 remain the same andare omitted hereby for simplicity.

FIG. 17 shows a flow chart of an exemplary method 1700 of operating anoptical encoder with a pixel array. A controller, such as a physicallyseparate computer system (e.g., a PC) and/or other microcontrollerunit(s) (e.g., an ASIC) may execute the operations of method 1700 byreading code from a computer-readable medium and executing the code toprovide the functionality discussed herein. At operation 1702, theoptical sensor IC retrieves a pixel partition map from a memory moduleafter a power up. In an embodiment, the optical sensor IC may run aninternal state machine that reads an external non-volatile memory toload the pixel partition map. At operation 1704, each pixel in the pixelarray is configured to a state defined in the pixel partition map, forexample the map defines each individual pixel into one of the fourquadrature regions discussed above or an OFF state. For example, controlsignals may be applied to switches (e.g., MUXs) to couple each pixelwith a respective current line. At operation 1706, at least one pixel ora set of pixels (e.g., a column or part of a column) is assigned to morethan one state. In some embodiments, a current duplicator copies acurrent output from the respective one pixel or a set of pixels to twoor more MUXs. The two or more MUXs subsequently route the copied currentoutputs to respective channel summing amplifiers with different states.Operationally, the method 1700 includes an operation 1708, which adjustsweights of outputs from the current duplicator. Alternatively, operation1706 may be optional and skipped, while operation 1708 directly adjustsweights of current outputs from at least one pixel or a set of pixels.

Which pixels or columns may be affected in operations 1706 and 1708 maybe determined by the system recording misalignment results, such as ajoint consideration of phase differences between adjacent quadraturecurrent waveforms and current magnitude balance. For instance,simulation or experimentation may be used to iteratively measure phasedifferences and then make adjustments to reach 90° phase differences. Atoperation 1710, the optical encoder performs an optical detection, bycollecting currents from different assigned regions on the pixel arrayin response to a light emitter that is modulated by a moving object,such as code slits rotating around a linear axis or sliding up/down alinear strip.

Using a pixel array with current weighting functions in an encodersystem also allows an alignment adjustment process to first map a lightintensity profile from the light source and then use the result to finetune a partition map during the regular operation. In the ideal case,the light source (e.g., a LED) in the encoder system would provide auniform light intensity for the diameter of the light source. In actualdesigns, the light source often exhibits a non-uniform light intensitydistribution with rolloff on the side and a non-flat top of the lightsource. In some embodiments, the light intensity profile fits a Gaussiandistribution. The adjustment process may first map light intensity byprogramming blocks of pixels and measuring the corresponding currentoutput to obtain an intensity profile map. This map may help todetermine pixels and respective current weights to be adjusted tomitigate non-uniform distribution in the illumination. This weightadjustment would then be overlaid on the pixel pattern during regularoperation to change weights of one or more pixels to provide a uniformsignal intensity for each of the quadrature channels. For example, anLED may have a higher output stripe near one quad grouping, such thatone quadrature region could be gained down compared with otherquadrature regions by selecting fewer pixels by setting one or morepixels to OFF state, or by using an analog technique such as assigning aweight (e.g., <1 for less gain or >1 for higher gain) to currentsgenerated by one or more pixels in the corresponding quadrature region.In a particular example, a peripheral region of the pixel array receivesless light intensity than a center region, while the weight adjustmentincreases the current outputs from the pixels in the peripheral regionand/or decreasing the current outputs from the pixels in the centerregion to compensate the light source non-uniformity.

FIG. 18 shows a flow chart of an exemplary method 1800 that combines thelight intensity non-uniformity compensation and normal (or mission mode)operation. Multiple operations in the method 1800 may be similar tothose in method 1700, which will be described briefly for simplicity. Acontroller, such as a physically separate computer system (e.g., a PC)and/or other microcontroller unit(s) may execute the operations ofmethod 1800 by reading code from a computer-readable medium andexecuting the code to provide the functionality discussed herein.

At operation 1802, the optical encoder retrieves a first pixel partitionmap from a memory module after a power up. In some embodiments, thefirst pixel partition map is specifically designed to benchmark theillumination profile and is different from the one used later on atoperation 1812 for normal operation purpose. In some embodiments, thefirst pixel partition map is the same with the one used later on atoperation 1812 for normal operation purpose. In an embodiment, theoptical sensor IC may run an internal state machine that reads anexternal non-volatile memory to load the map. At operation 1804, eachpixel in the pixel array is configured to a state defined in the firstpixel partition map, for example the map defines each individual pixelinto one of the four quadrature regions discussed above or an OFF state.For example, control signals may be applied to switches (e.g., MUXs) tocouple each pixel with a respective current line. At operation 1806, thelight intensity profile from the light source is measured by the pixelarray. At operation 1808, based on the measured light intensityprofiled, one or more pixels are determined to be adjusted to mitigatenon-uniform distribution in the illumination. The adjustment may includechanging weights assigned to the currents corresponding to the selectedpixels, such as setting the selected pixels to reduce gain or toincrease gain with a purpose of creating four sine waves of equalamplitude separated by 90°. At operation 1810, the determined weightsare stored in the memory module.

At operation 1812, the optical encoder retrieves a second pixelpartition map from the memory module. The second pixel partition mapcorresponds to the quadrature tracks on a code wheel and will be usedfor normal operation. At operation 1814, the current weights of pixelsselected at operation 1808 is adjusted, such as by retrieving thedetermined weights from the memory module and overlaying the weights onthe second pixel partition map. As discussed above, the adjustment mayinclude setting the selected pixels to reduce current output (or set toOFF) or to increase current output. Subsequently, at operation 1816, theoptical encoder performs an optical detection, by collecting currentsfrom different assigned regions on the pixel array in response to alight emitter that is modulated by a moving object, such as code slitsrotating around a linear axis or sliding up/down a linear strip.

The optical encoder in the present disclosure may be adapted for use inboth transmissive and reflective architectures. The description here isfor a transmissive design where the LED is on one side of the code wheeland the detector is on the other. In a reflective design, the LED sitson the same side with the detector IC, either on-chip or off-chip withthe detector IC, and reflects light off the code wheel with reflective“slits” and non-reflective spaces. This may provide a smaller systemdesign. The pixel array supports both transmissive and reflectivearchitectures. In an exemplary reflective design, the LED is on the samedie with the detector IC. In another exemplary reflective design, theLED and the detector IC are on two separate devices (e.g., two dies) butphysically assembled together.

The concepts discussed herein can be applied to linear encoders as wellas rotary encoders. In a linear design, the equivalent of code slitswould be on a linear axis and slide up/down the pixel array. The pixelarray would work equally well in that scenario. For example, in a linearencoder embodiment the motion object may include pulses-per-length, asopposed to a rotary encoder that uses radius and PPR.

The pixels may be constructed with configurations accessed either from arandom-access memory (RAM) or from a non-volatile memory (NVM). In thecase of RAM, a host microcontroller may set each memory. Alternatively,the encoder ASIC may contain logic to read from an external NVM or aninternal NVM and set the memory that way. Internal NVM may beprogrammable—i.e., flash, or may be a one-time-programmable memory. Thepixels may also be set using a read-only memory (ROM) to store staticpattern although that reduces the advantage of user flexibility. Userswith sufficient volume may order a ROM pattern to eliminate the need toconfigure the memory at run time.

In various embodiments, the pixel array may have configurable pixelsthat may be set by a memory to map to one of the four channels. Theconfigurable pixels may be set either by a host microcontroller, usingan internal non-volatile memory with a circuit to read and set, or byusing a masked ROM where the pixels are set in some factory alignmentconfiguration. However, various embodiments may use any appropriateprocessor or memory. Furthermore, in-system configurability is possiblefor some embodiments. Encoder manufacturers may apply a patch in thefield, updating the pixel map after the product has been installed inthe field. This patch may improve or otherwise change performancecharacteristics.

Also, the lack of a visible phased-array pattern makes the design lesssusceptible to cloning. Traditionally, a regular phased-array can beobserved under a microscope to determine size of features thus allowinga competitor to copy the design. The pixel array does not have anyindication of mapping thus requiring the I²C or other protocol stream tobe interrupted in order to determine which pixels are mapped to whichquadrature region. This would be considerably more difficult to copy.

Moreover, the configurable pixel arrays may also allow a user to usesame IC to develop a product portfolio of difference performance levels,for example by setting different thresholds to limit an opticalencoder's precision level. Therefore, encoder manufacturers may providedifferent performance/price points with a common set of hardwareincluding code wheel. Remapping the pixel array with a common code wheelmay allow different performance of the resulting system. Encodermanufacturers may offer higher or lower price points based onperformance with identical hardware thus allowing them to market theirproducts differently.

The principle of the present disclosure may also be applicable to amagnetic encoder as to an optical encoder. For example, in a magneticencoder, instead of a configurable photodetector array including aplurality of photodetectors, the system may have a configurablemagnetic-field detector array including a plurality of magneticdetectors. A magnetized part in the emitter generates a magnetic flux.The configurable magnetic-field detector detects changes of the magneticflux modulated by the moving object, such as a code wheel or a codestripe. The other aspects of the magnetic encoder are similar to whathave been described above in the optical encoder and omitted here forthe sake of simplicity.

The foregoing outlines features of several embodiments so that thoseskilled in the art may better understand the aspects of the presentdisclosure. Those skilled in the art should appreciate that they mayreadily use the present disclosure as a basis for designing or modifyingother processes and structures for carrying out the same purposes and/orachieving the same advantages of the embodiments introduced herein.Those skilled in the art should also realize that such equivalentconstructions do not depart from the spirit and scope of the presentdisclosure, and that they may make various changes, substitutions, andalterations herein without departing from the spirit and scope of thepresent disclosure.

What is claimed is:
 1. An encoder system, comprising: a light emitterconfigured to emit a light flux; a plurality of photodetectors in anarray, wherein each photodetector is operable to generate a current inresponse to the light flux, and wherein each photodetector has achangeable state assignment; a plurality of multiplexers configured toroute each one of the currents according to a respective changeablestate assignment; and a current duplicator configured to duplicate afirst one of the currents to feed two of the multiplexers.
 2. Theencoder system of claim 1, wherein the changeable state assignment isone of a plurality of quadrature states or OFF.
 3. The encoder system ofclaim 2, wherein each photodetector from a same column of the array hasa same quadrature state or OFF.
 4. The encoder system of claim 1,further comprising a current weight adjustor configured to increase ordecrease the duplicated first current.
 5. The encoder system of claim 1,wherein the current duplicator includes a current weight adjustingfunction configured to increase or decrease the duplicated firstcurrent.
 6. The encoder system of claim 1, wherein the first current isgenerated by a single photodetector.
 7. The encoder system of claim 1,wherein the first current is generated by multiple photodetectors from asame column of the array.
 8. The encoder system of claim 1, wherein thetwo multiplexers have different changeable state assignments.
 9. Theencoder system of claim 1, wherein the two multiplexers have a samechangeable state assignment.